import Vue from 'vue'
import {
  Button,
  NavBar,
  Tabbar, TabbarItem,
  Swipe, SwipeItem,
  Toast
  , Grid, GridItem, Card, Tab, Tabs, Lazyload, ImagePreview, Panel, Stepper, Switch, SubmitBar, Checkbox, CheckboxGroup } from 'vant'

Vue.use(Checkbox).use(CheckboxGroup)
  .use(SubmitBar)
  .use(Switch)
  .use(Stepper)
  .use(Panel)
// options 为可选参数，无则不传
  .use(Lazyload, {
    loading: 'https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1576562199487&di=af4158ae711bc5a9a845300f178eadc4&imgtype=0&src=http%3A%2F%2Fimglf6.nosdn.127.net%2Fimg%2FMjB0dFlYR2VYNXFIWVUwMWp3T1JEUXBIUlp5Y29LeHZINy9GcnJTZVFIMW40Y0ZsUVgwVDV3PT0.gif'
  })
  .use(Tab).use(Tabs)
  .use(Grid).use(GridItem)
  .use(Swipe).use(SwipeItem)
  .use(Tabbar).use(TabbarItem)
  .use(NavBar)
  .use(Button)
  .use(Card)

Vue.prototype.$Toast = Toast
Vue.prototype.$ImagePreview = ImagePreview
